﻿using UnityEngine;
using System.Collections;

public class Node : MonoBehaviour 
{

	public nodeState currentState = nodeState.EMPTY;
	public int distanceSteps = 10000;
	public bool hasPath = false;

	public bool checkCollision;

	void OnTriggerEnter2D(Collider2D collision)
	{
		if(!checkCollision && collision.gameObject.layer == 8)
		{
			checkCollision = true;
			currentState = nodeState.WALL;
		}
	}
}

public enum nodeState
{
	EMPTY,
	ORIGIN,
	GOAL,
	WALL
}
